import axios from '@/libs/request/axios'
export const listHoliday = () => {
    return axios.request({
        url: '/admin/holiday/listHoliday',
        method: 'get'
    })
}

export const listHolidayByYear = (year) => {
    return axios.request({
        url: '/admin/holiday/listHolidayByYear',
        params:{year:year},
        method: 'get'
    })
}

export const holiday = (year) => {
    return axios.request({
        url: `/admin/holiday/${year}`,
        method: 'get'
    })
}

export const saveHoliday = (year,holidayInfo) => {
    return axios.request({
        url: `/admin/holiday/saveHoliday`,
        params: {year:year,holidayInfo:holidayInfo},
        method: 'post'
    })
}
